﻿<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2"
                assembly="Inovout.Security"
				       namespace="Inovout.Security">

  <class name="Permission" table="Security_Permission">
    <id name="Id" access="field.camelcase"
        column="PermissionId" type="Int32">
      <generator class="native" />
    </id>
    <many-to-one name="Privilege" column="PrivilegeId" class="Inovout.Security.Privilege,Inovout.Security" />
    <any name="Actor" id-type="int" meta-type="string">
      <meta-value value="Role" class="Inovout.Security.Role,Inovout.Security"/>
      <!--<meta-value value="User" class="Inovout.Security.User,Inovout.Security"/>
      <meta-value value="FormsUser" class="Inovout.Security.FormsUser,Inovout.Security"/>
      <meta-value value="OpenIdUser" class="Inovout.Security.OpenIdUser,Inovout.Security"/>-->
      <meta-value value="SystemUser" class="Inovout.Security.SystemUser,Inovout.Security" />
      <!--<meta-value value="ApplicationUser" class="Inovout.Cloud.Applications.Security.Models.ApplicationUser,Inovout.Cloud.Applications"/>-->
      <column name="ActorType" not-null="true"/>
      <column name="ActorId" not-null="true"/>
    </any>
    <property name="CreatedTime" access="field.camelcase" />
    <property name="CreatedUserName" access="field.camelcase" />
    <property name="ModifiedTime" access="field.camelcase" />
    <property name="ModifiedUserName" access="field.camelcase" />
    <property name="AccessedTime" access="field.camelcase" />
    <property name="AccessedUserName" access="field.camelcase" />
    <property name="Memo" />
    <property name="IsInvalid" />
  </class>
</hibernate-mapping>


